package hr_project.hr.biz.role;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import hr_project.hr.dao.IRoleDao;
import hr_project.hr.entity.Role;
import hr_project.hr.entity.Role_Right;

@Service
public class RoleBizImpl implements IRoleBiz {
	@Autowired
	private IRoleDao dao;
	

	public IRoleDao getDao() {
		return dao;
	}

	public void setDao(IRoleDao dao) {
		this.dao = dao;
	}

	@Override
	public Role getRoleByid(long rid) {
		// TODO Auto-generated method stub
		return dao.getRoleByid(rid);
	}

	@Override
	public void addRole(Role role) {
		// TODO Auto-generated method stub
		dao.addRole(role);
	}

	@Override
	public List<Role> getAllRole() {
		// TODO Auto-generated method stub
		return dao.getAllRole();
	}

	@Override
	public void delRole(long ro_id) {
		// TODO Auto-generated method stub
		dao.delRole(ro_id);
	}

	@Override
	public void addright(Role_Right rr) {
		// TODO Auto-generated method stub
		dao.addright(rr);
	}

	@Override
	public void delRoleRight(long ro_id) {
		// TODO Auto-generated method stub
		dao.delRoleRight(ro_id);
	}

	@Override
	public void deloneRight(Role_Right rr) {
		// TODO Auto-generated method stub
		dao.deloneRight(rr);
	}

	

}
